import 'dart:typed_data';

class CarInfo{
  String code;
  Uint8List? frame;

  CarInfo({required this.code, this.frame});

  Map<String, dynamic> toMap() {
    return {
      'code': code,
      'frame': frame,
    };
  }

  factory CarInfo.fromMap(dynamic map) {
    return CarInfo(
      code: map['code'] as String,
      frame: map['frame'] as Uint8List?,
    );
  }
}